home *** CD-ROM | disk | FTP | other *** search
/ IRIX Base Documentation 2002 November / SGI IRIX Base Documentation 2002 November.iso / usr / share / catman / p_man / cat4 / passwd.z / passwd
Encoding:
Text File  |  2002-10-03  |  11.0 KB  |  265 lines

  1.  
  2.  
  3.  
  4. ppppaaaasssssssswwwwdddd((((4444))))                                                            ppppaaaasssssssswwwwdddd((((4444))))
  5.  
  6.  
  7.  
  8. NNNNAAAAMMMMEEEE
  9.      passwd - password file
  10.  
  11. DDDDEEEESSSSCCCCRRRRIIIIPPPPTTTTIIIIOOOONNNN
  12.      /_e_t_c/_p_a_s_s_w_d is an ASCII file containing entries for each user.  Each
  13.      field within each user's entry is separated from the next by a colon.
  14.      Each user is separated from the next by a newline.  An entry beginning
  15.      with # is ignored, and may be silently removed under some circumstances
  16.      (see _p_a_s_s_w_d(1) for specific information.)
  17.  
  18.      The _p_a_s_s_w_d file contains the following information for each user:
  19.  
  20.      name      User's login name -- consists of alphanumeric characters and
  21.                must not be greater than eight characters long.  It is
  22.                recommended that the login name consist of a leading lower case
  23.                letter followed by a combination of digits and lower case
  24.                letters for greatest portability across multiple versions of
  25.                the UNIX operating system.  This recommendation can be safely
  26.                ignored for users local to IRIX systems.  The _p_w_c_k(1M) command
  27.                checks for the greatest possible portability on names, and
  28.                complains about user names that do not cause problems on IRIX.
  29.  
  30.      password  Encrypted password and optional password aging information.  If
  31.                the password field is null (empty), no password is demanded
  32.                when the user logs in.  If the system is configured to use
  33.                shadow passwords, this field of /_e_t_c/_p_a_s_s_w_d is ignored by all
  34.                programs that do password checking.  See _p_w_c_o_n_v(1M) for
  35.                information about shadow passwords.
  36.  
  37.      numerical user ID
  38.                This is the user's ID in the system and it must be unique.
  39.  
  40.      numerical group ID
  41.                This is the number of the default group that the user belongs
  42.                to.
  43.  
  44.      user's real name
  45.                In some versions of UNIX, this field also contains the user's
  46.                office, extension, home phone, and so on.  For historical
  47.                reasons this field is called the GECOS field.  The _f_i_n_g_e_r(1)
  48.                program can interpret the GECOS field if it contains comma
  49.                (``,'') separated subfields as follows:
  50.  
  51.                name     user's full name
  52.                office   user's office number
  53.                wphone   user's work phone number
  54.                hphone   user's home phone number
  55.  
  56.                An & in the user's full name field stands for the login name
  57.                (in cases where the login name appears in a user's real name).
  58.  
  59.  
  60.  
  61.  
  62.  
  63.                                                                         PPPPaaaaggggeeee 1111
  64.  
  65.  
  66.  
  67.  
  68.  
  69.  
  70. ppppaaaasssssssswwwwdddd((((4444))))                                                            ppppaaaasssssssswwwwdddd((((4444))))
  71.  
  72.  
  73.  
  74.      initial working directory
  75.                The directory that the user is positioned in when they log in;
  76.                this is known as the home directory.
  77.  
  78.      shell     The program to use as the command interpreter (shell) when the
  79.                user logs in.  If the _s_h_e_l_l field is empty, the Bourne shell
  80.                (/_b_i_n/_s_h) is assumed.  If the first character of this field is
  81.                an ****, then the _l_o_g_i_n(1) program treats the home directory field
  82.                as the directory to be used as the argument to the _c_h_r_o_o_t(2)
  83.                system call, and then loops back to reading the /_e_t_c/_p_a_s_s_w_d
  84.                file under the new root, reprompting for the login.  This can
  85.                be used to implement secure or restricted logins, in a manner
  86.                similar to _f_t_p(1C).
  87.  
  88.      Password aging is used for a particular user if his encrypted password is
  89.      followed by a comma and a non-null string of characters from a 64-
  90.      character alphabet (.,/,0-9, A-Z, a-z) parsed left to right by _a_6_4_l(3)).
  91.      The first character of the age, _M say, denotes the maximum number of
  92.      weeks for which a password is valid.  A user who attempts to login after
  93.      his password has expired is forced to change his password.  The next
  94.      character, _m say, denotes the minimum period in weeks that must expire
  95.      before the password can be changed.  If the second character is omitted,
  96.      zero weeks is the default minimum.  _M and _m have numerical values in the
  97.      range 0-63 that correspond to the 64-character alphabet shown above (//// =
  98.      1 week, zzzz = 63 weeks).  The remaining characters are the weeks since the
  99.      epoch when the password was last changed.  If _m = _M = 0 (derived from the
  100.      string .... or ........) the user is forced to change his password the next time
  101.      he logs in (and the age disappears from his entry in the password file).
  102.      If _m > _M only the superuser is able to change the password.  The password
  103.      must have been previously changed and therefore have a valid last change
  104.      date in the aging field for this _m > _M mechanism to control password
  105.      manipulation.  Simply putting ....//// as the aging string will be interpreted
  106.      by llllooooggggiiiinnnn as an expired password (because the last changed date is 0), and
  107.      the automatic invocation of ppppaaaasssssssswwwwdddd by llllooooggggiiiinnnn will fail due to the _m > _M
  108.      mechanism.
  109.  
  110.      The password file resides in the /_e_t_c directory.  Because of the
  111.      encrypted passwords, it has general read permission and can be used, for
  112.      example, to map numerical user ID's to names.
  113.  
  114. NNNNIIIISSSS EEEENNNNTTTTRRRRIIIIEEEESSSS
  115.      If the NFS option is installed, the _p_a_s_s_w_d file can also have lines
  116.      beginning with a `++++' (plus sign) which means to incorporate entries from
  117.      the NIS.  There are three styles of ++++ entries in this file:
  118.  
  119.      +            Means to insert the entire contents of the NIS password file
  120.                   at that point.
  121.  
  122.      +name        Means to insert the entry (if any) for _n_a_m_e from the NIS at
  123.                   that point.
  124.  
  125.  
  126.  
  127.  
  128.  
  129.                                                                         PPPPaaaaggggeeee 2222
  130.  
  131.  
  132.  
  133.  
  134.  
  135.  
  136. ppppaaaasssssssswwwwdddd((((4444))))                                                            ppppaaaasssssssswwwwdddd((((4444))))
  137.  
  138.  
  139.  
  140.      +@netgroup   Means to insert the entries for all members of the network
  141.                   group _n_e_t_g_r_o_u_p at that point.
  142.  
  143.      If a + entry has a non-empty password, directory, GECOS, or shell field,
  144.      the value of that field overrides what is contained in the NIS.  The _u_i_d
  145.      and _g_i_d fields cannot be overridden.
  146.  
  147.      The _p_a_s_s_w_d file can also have lines beginning with a `----' (minus sign)
  148.      which means to disallow entries from the NIS (or from local use).  There
  149.      are two styles of `----' entries in this file:
  150.  
  151.      -name        Means to disallow any subsequent entries (if any) for _n_a_m_e
  152.                   (in this file or in the NIS).
  153.  
  154.      -@netgroup   Means to disallow any subsequent entries for all members of
  155.                   the network group _n_e_t_g_r_o_u_p.
  156.  
  157.      Password aging is not supported for NIS entries.
  158.  
  159. UUUUIIIIDDDD CCCCOOOONNNNVVVVEEEENNNNTTTTIIIIOOOONNNNSSSS
  160.      User ID number restrictions and conventions in the UNIX community are few
  161.      and simple.
  162.  
  163.      Reserved:
  164.  
  165.           UID 0         The superuser (aka root).
  166.  
  167.           UID -2        NFS 'nobody'.  Note that because uid_t is unsigned, -2
  168.                         is mapped to the special value 60001 by NFS.
  169.  
  170.           UID 60001 and 60002
  171.                         For historical reasons, these values correspond to the
  172.                         users ``nobody'' and ``noaccess'', respectively.  It
  173.                         is recommended that you not allocate these values to
  174.                         real users.
  175.  
  176.      Conventions:
  177.  
  178.           UID 1 to 10   Commonly used for system pseudo users and daemons.
  179.  
  180.           UID 11 to 99  Commonly used for uucp logins and 'famous users'.
  181.  
  182.           UID 100 to 2147483647 (except for 60001 and 60002)
  183.                         Normal users (start at 100).  For historical reasons
  184.                         certain operations are restricted for uids larger than
  185.                         65535.  Most significantly, these users cannot own
  186.                         files on an _e_f_s(4) filesystem.  This also means that
  187.                         they cannot run a program that allocates a _p_t_y(7M)
  188.                         (for example, _v_i(1) and _x_w_s_h(1G)) if /_d_e_v resides on
  189.                         an _e_f_s(4) filesystem.
  190.  
  191.  
  192.  
  193.  
  194.  
  195.                                                                         PPPPaaaaggggeeee 3333
  196.  
  197.  
  198.  
  199.  
  200.  
  201.  
  202. ppppaaaasssssssswwwwdddd((((4444))))                                                            ppppaaaasssssssswwwwdddd((((4444))))
  203.  
  204.  
  205.  
  206.                         For these reasons, we recommend that large uids only
  207.                         be used on _x_f_s(4) based systems.
  208.  
  209. EEEEXXXXAAAAMMMMPPPPLLLLEEEE
  210.      Here is a sample /_e_t_c/_p_a_s_s_w_d file:
  211.  
  212.           root:q.mJzTnu8icF.:0:10:superuser:/:/bin/csh
  213.           bill:6k/7KCFRPNVXg,z/:508:10:& The Cat:/usr2/bill:/bin/csh
  214.           +john:
  215.           +@documentation:no-login:
  216.           +::::Guest
  217.           nobody:*:-2:-2::/dev/null:/dev/null
  218.  
  219.      In this example, there are specific entries for users _r_o_o_t and _b_i_l_l, to
  220.      assure that they can log in even when the system is running stand-alone
  221.      or when the NIS is not running.  The user _b_i_l_l has 63 weeks of maximum
  222.      password aging and 1 week of minimum password aging.  Programs that use
  223.      the GECOS field replace the & with `Bill'.  The user _j_o_h_n has his
  224.      password entry in the NIS incorporated without change; anyone in the
  225.      netgroup _d_o_c_u_m_e_n_t_a_t_i_o_n has their password field disabled, and anyone else
  226.      is able to log in with their usual password, shell, and home directory,
  227.      but with a GECOS field of _G_u_e_s_t. The user _n_o_b_o_d_y cannot log in and is
  228.      used by the _e_x_p_o_r_t_f_s(1M) command.
  229.  
  230. FFFFIIIILLLLEEEESSSS
  231.      /etc/passwd
  232.  
  233. SSSSEEEEEEEE AAAALLLLSSSSOOOO
  234.      login(1), passwd(1), pwck(1M), pwconv(1M), ypchpass(1), yppasswd(1),
  235.      a64l(3C), crypt(3C), getpwent(3C), exports(4), group(4), netgroup(4),
  236.      shadow(4).
  237.  
  238.  
  239.  
  240.  
  241.  
  242.  
  243.  
  244.  
  245.  
  246.  
  247.  
  248.  
  249.  
  250.  
  251.  
  252.  
  253.  
  254.  
  255.  
  256.  
  257.  
  258.  
  259.  
  260.  
  261.                                                                         PPPPaaaaggggeeee 4444
  262.  
  263.  
  264.  
  265.